set(io_fs_files
	"BaseFileSystem.h"
	"BaseFileSystem.cpp"
	"StdFileSystem.h"
	"StdFileSystem.cpp"
)

set(io_stream_files
	"BaseIStream.h"
	"BaseOStream.h"
)

set(io_main_files
	"Path.cpp"
	"Path.h"
	"Path.inl"
	"StreamUtils.cpp"
	"StreamUtils.h"
)

set(io_mmf_files
	"MemoryMappedFile.h"
	"MemoryMappedFile.inl"
    "MemoryMappedFileTypes.h"
)

if(MSVC)

set(io_fs_files
	${io_fs_files}
	"win32/StdFileSystem_win32.cpp"
)

set(io_mmf_files
    ${io_mmf_files}
    "win32/MemoryMappedFile_win32.h"
    "win32/MemoryMappedFile_win32.inl"
    "win32/MemoryMappedFile_win32.cpp"
)

elseif(UNIX)

set(io_fs_files
	${io_fs_files}
	"unix/StdFileSystem_unix.cpp"
)

set(io_mmf_files
    ${io_mmf_files}
    "unix/MemoryMappedFile_unix.h"
    "unix/MemoryMappedFile_unix.inl"
    "unix/MemoryMappedFile_unix.cpp"
)

endif()

set(io_all_files
	${common_misc_files}
	${io_fs_files}
	${io_stream_files}
	${io_mmf_files}
	${io_main_files}
)

add_library(io ${io_all_files})
add_libs_target(io)

source_group(fs FILES ${io_fs_files})
source_group(stream FILES ${io_stream_files})
source_group(mmf FILES ${io_mmf_files})
source_group(main FILES ${io_main_files})

#include (${TOOLS_ROOT}/common.cmake)
add_common_properties(io)